<?php

use Illuminate\Database\Seeder;

class ArticleSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
    	$data = [];
    	for($i=0;$i<=100;$i++){
    		$temp['title'] = str_random(5);
	        $temp['des'] = str_random(10);
	        $temp['pic'] = './uploads/8dafbe6dc65796e9ed9b6c69d17f1f92.jpg';
	        $temp['cid'] = rand(1,4);
	        $temp['uid'] = 1;
	        $temp['con'] = '<p>美女;<img src="/ueditor/20170824/1503543170810245.jpg" title="1503543170810245.jpg" alt="14.jpg"/></p>';
	        $temp['time'] = time();
	        $data[] = $temp;
    	}

        DB::table('article')->insert($data);

    }
}
